package sh.entity;

import java.sql.Timestamp;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;

/**
 * (Message)实体类
 *
 * @author makejava
 * @since 2021-05-10 16:30:59
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@ApiModel(value = "留言消息类")
public class Message implements Serializable {
    private static final long serialVersionUID = 852521736457203000L;
    /**
     * 留言id
     */
    @ApiModelProperty(hidden = true)
    private Integer messageId;
    /**
     * 留言内容
     */
    @NotNull(message = "留言内容不能为空")
    @ApiModelProperty(name = "留言内容",dataType = "string",notes = "留言内容")
    private String messageContent;
    /**
     * 发送人类型 1老师、任课老师、管理员 2学生 3家长
     */
    @NotNull(message = "发送人类型不能为空")
    @ApiModelProperty(name = "发送人类型",dataType = "int", notes = "发送人类型 1老师、任课老师、管理员 2学生 3家长")
    private Integer messageSendType;
    /**
     * 发送人id
     */
    @NotNull(message = "发送人id不能为空")
    @ApiModelProperty(name = "发送人id",dataType = "int",notes = "发送人id")
    private Integer messageSendPersonId;
    /**
     * 接收人类型 1老师、任课老师、管理员 2学生 3家长
     */
    @NotNull(message = "接收人类型不能为空")
    @ApiModelProperty(name = "接收人类型",dataType = "int", notes = "接收人类型 1老师、任课老师、管理员 2学生 3家长")
    private Integer messageReceiveType;
    /**
     * 接收人id
     */
    @NotNull(message = "接收人id不能为空")
    @ApiModelProperty(name = "接收人id",dataType = "int",notes = "接收人id")
    private Integer messageReceiveId;
    /**
     * 消息是否已读 0未读 1已读
     */
    @ApiModelProperty(hidden = true, name = "消息是否已读",dataType = "int", notes = "消息是否已读 0未读 1已读")
    private Integer messageStatus;
    /**
     * 消息是否被删除 0未删除 1已删除
     */
    @ApiModelProperty(hidden = true, notes = "消息是否被删除 0未删除 1已删除")
    private Integer messageIsDeleted;

    @ApiModelProperty(hidden = true, notes = "消息创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp messageCreateTime;
    /**
     * 留言更新时间
     */
    @ApiModelProperty(hidden = true, notes = "留言更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp messageUpdateTime;

}
